module CharacterTraitsHelper
  def character_traits (character, separator = ", ")
    return nil unless character
    list = Array.new
    if character.character_traits
      character.character_traits.each do |ct|
        list = list << ct.trait.name
      end
    end
    list.join(separator)
  end
end
